package db;

import bean.User;

import java.util.Collection;
import java.util.LinkedHashMap;
import java.util.Map;

public class UserMockTable {
    private static Map<String, User> users=new LinkedHashMap<String, User>();

    static {
        users.put("张三1",new User("张三1","123"));
        users.put("张三2",new User("张三2","123"));
        users.put("张三3",new User("张三3","123"));
        users.put("张三4",new User("张三4","123"));
        users.put("张三5",new User("张三5","123"));
    }

    public static Collection<User> getAllUsers(){
        return users.values();
    }

    public static User getUserByName(String name){
        return users.get(name);
    }
}
